You can rotate your shape using the small rotation handle located at the right-hand side of the object. Click and hold down the left mouse button on the rotation handle and drag it to the desired position.
Rotating a rectangle with the rotation handle
You can rotate the rectangle more precisely by using the rotation controls at the bottom of the Tool Settings Panel, or by choosing Rotate from the Image menu. Grab the circular rotation knob and, without letting go of the left mouse button, rotate it to any degree. You can also rotate your selection by clicking on one of the preset arrow buttons or by typing in an exact number of degrees.
Rotating your shape using the rotation controls